package com.entity;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * @author 
 */
public class Orderinfo implements Serializable {
    private String orid;

    private String shid;

    private String buid;

    private Date ortime;

    private Integer orcount;

    private Integer orsum;

    private Integer orstate;

    List<Orderdetail> orderdetails;

    public List<Orderdetail> getOrderdetails() {
        return orderdetails;
    }

    public void setOrderdetails(List<Orderdetail> orderdetails) {
        this.orderdetails = orderdetails;
    }

    private static final long serialVersionUID = 1L;

    public String getOrid() {
        return orid;
    }

    public void setOrid(String orid) {
        this.orid = orid;
    }

    public String getShid() {
        return shid;
    }

    public void setShid(String shid) {
        this.shid = shid;
    }

    public String getBuid() {
        return buid;
    }

    public void setBuid(String buid) {
        this.buid = buid;
    }

    public Date getOrtime() {
        return ortime;
    }

    public void setOrtime(Date ortime) {
        this.ortime = ortime;
    }

    public Integer getOrcount() {
        return orcount;
    }

    public void setOrcount(Integer orcount) {
        this.orcount = orcount;
    }

    public Integer getOrsum() {
        return orsum;
    }

    public void setOrsum(Integer orsum) {
        this.orsum = orsum;
    }

    public Integer getOrstate() {
        return orstate;
    }

    public void setOrstate(Integer orstate) {
        this.orstate = orstate;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Orderinfo other = (Orderinfo) that;
        return (this.getOrid() == null ? other.getOrid() == null : this.getOrid().equals(other.getOrid()))
            && (this.getShid() == null ? other.getShid() == null : this.getShid().equals(other.getShid()))
            && (this.getBuid() == null ? other.getBuid() == null : this.getBuid().equals(other.getBuid()))
            && (this.getOrtime() == null ? other.getOrtime() == null : this.getOrtime().equals(other.getOrtime()))
            && (this.getOrcount() == null ? other.getOrcount() == null : this.getOrcount().equals(other.getOrcount()))
            && (this.getOrsum() == null ? other.getOrsum() == null : this.getOrsum().equals(other.getOrsum()))
            && (this.getOrstate() == null ? other.getOrstate() == null : this.getOrstate().equals(other.getOrstate()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getOrid() == null) ? 0 : getOrid().hashCode());
        result = prime * result + ((getShid() == null) ? 0 : getShid().hashCode());
        result = prime * result + ((getBuid() == null) ? 0 : getBuid().hashCode());
        result = prime * result + ((getOrtime() == null) ? 0 : getOrtime().hashCode());
        result = prime * result + ((getOrcount() == null) ? 0 : getOrcount().hashCode());
        result = prime * result + ((getOrsum() == null) ? 0 : getOrsum().hashCode());
        result = prime * result + ((getOrstate() == null) ? 0 : getOrstate().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", orid=").append(orid);
        sb.append(", shid=").append(shid);
        sb.append(", buid=").append(buid);
        sb.append(", ortime=").append(ortime);
        sb.append(", orcount=").append(orcount);
        sb.append(", orsum=").append(orsum);
        sb.append(", orstate=").append(orstate);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}